package com.youlu.campus.entity;

import com.youlu.campus.base.base.EntityBase;
import lombok.Getter;
import lombok.Setter;
import org.springframework.data.mongodb.core.index.Indexed;
import org.springframework.data.mongodb.core.mapping.Document;

import java.util.Date;

/**
 * 活动自动化任务
 */
@Getter
@Setter
@Document(collection = "activity_auto_task")
public class ActivityAutoTask extends EntityBase {
    /**
     * 任务名
     */
    private String name;

    @Indexed
    private String activityId;
    private String activityName;
    /**
     * 任务类型
     * form:表单
     */
    @Indexed
    private String type;
    /**
     * 业务ID,
     * 类型表单：表单ID
     * 类型志愿服务：志愿服务任务ID
     */
    private String bizId;
    private String bizName;
    private Date startTime;
    private Date endTime;
    /**
     * 活动任务DI
     */
    private String activityTaskId;
    /**
     * 贡献值
     */
    private Double q;
    /**
     * 状态
     * todo:未执行
     * doing:运行中
     * done:完成
     * withdrawing:撤销中
     * withdrawed:已撤销
     */
    private String status = "todo";
    /**
     * 总数量
     */
    private Integer count;
    /**
     * 操作人名
     */
    private String optUserName;
    /**
     * 操作人用户ID
     */
    private String optUserId;
    /**
     * 持续时间，单位：秒
     */
    private Integer duration;




}
